cmake_minimum_required(VERSION 2.8)

# CMakeLists variables
# Indirection lvl to the root of the project
set(INDIRECTION_LVL ${CMAKE_CURRENT_SOURCE_DIR}/../..)
set(DEPENDENCY_PATH ${INDIRECTION_LVL}/Dependencies)

# Project settings
set(LIB_NAME PROJECT_NAME)

# Compilation option
if (${CMAKE_CXX_COMPILER_ID} STREQUAL "Clang")
	set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11 -Wno-reorder -Wno-switch-enum")
elseif (${CMAKE_CXX_COMPILER_ID} STREQUAL "GNU")
	set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++0x")
endif ()


set(HEADERS
	bitfield.h
	Comparator.classdef.h
	Comparator.h
	flags.h
	Iterator.classdef.h
	Iterator.h
	TComposition.h
	TVisitor.classdef.h
	TVisitor.h
	)

set(SOURCES
	BitField.cpp
	Comparator.cpp
	Iterator.cpp
	)

source_group("" FILES ${HEADERS} ${SOURCES})

include_directories(
	../
	${DEPENDENCY_PATH}/boost_1_48_0
	)

add_library(${LIB_NAME} STATIC ${HEADERS} ${SOURCES})
